MyAddFrameFunction
The sequence grabber component calls your add-frame function in order to add a frame to a movie. Your add-frame function must support the following interface:
pascal ComponentResult MyAddFrameFunction (SGChannel c, short bufferNum, TimeValue atTime, TimeScale scale, SGCompressInfo *ci, long refCon);
c
- Specifies the reference that identifies the channel for this operation.
bufferNum
- Identifies the buffer for this operation. You can obtain information about this buffer by calling the
SGGetBufferInfo
function, which is described on page 5-98.atTime
- Specifies the time at which the frame was captured, in the time scale specified by the
scale
parameter. Your add-frame function can change this value before adding the frame to the movie or before calling theSGAddFrame
function, which is described on page 5-103. You can determine the duration of a frame by subtracting its capture time from the capture time of the next frame in the sequence.scale
- Specifies the time scale of the movie. You must not change this value.
ci
- Contains a pointer to a compression information structure (defined by the
SGCompressInfo
data type). This structure contains information describing the compression characteristics of the image to be added to the movie. See "The Compression Information Structure" beginning on page 5-20 for a description of this structure.refCon
- Contains a reference constant value. You can set this value by calling the
SGSetChannelRefCon
function, which is described on page 5-64.DESCRIPTION
You can use your add-frame function to modify the contents of the frame before it is added to the movie. This can be useful if you want to place frame numbers onto frames you are recording.RESULT CODES
Memory Manager errors
cantDoThatInCurrentMode -9402 Request invalid in current mode SEE ALSO
Your add-frame function can use the sequence grabber component'sSGAddFrame
function to support the default behavior.SGAddFrame
is described on page 5-103.
Main | Top of Section | What's New | Apple Computer, Inc. | Find It | Feedback | Help